package models

import (
	"gorm.io/gorm"
)

type PetInfo struct {
	gorm.Model
	PetName string `gorm:"type:varchar(50) not null" json:"pet_name"`
	PetSex  string `gorm:"type:enum('公','母')" json:"pet_sex"`
	PetAge  int    `gorm:"type:int" json:"pet_age"`
	Img     string `gorm:"type:text" json:"img"`
}

type UserInfo struct {
	gorm.Model
	Username   string `gorm:"type:varchar(30) not null" json:"username"`
	Password   string `gorm:"type:varchar(50) not null" json:"password"`
	PeopleName string `gorm:"type:varchar(30) not null" json:"peopleName"`
	PetId      int    `gorm:"type:int" json:"petId"`
}

type PetUser struct {
	gorm.Model
	PetID  int `gorm:"type:int" json:"pet_id"`
	UserId int `gorm:"type:int" json:"user_id"`
}

type PetCate struct {
	gorm.Model
	CateName string `gorm:"type:varchar(30) not null" json:"cate_name"`
}
